//
//  RXFrameRichLabel.h
//  RXFrame
//
//  Created by srxboys on 2021/4/22.
//

#import <UIKit/UIKit.h>
#import <CoreText/CoreText.h>

NS_ASSUME_NONNULL_BEGIN

@interface RXFrameRichLabel : UILabel

@property (nonatomic, assign) UIEdgeInsets contentInset;

@property (nonatomic, copy) NSString *iconName;

@property (nonatomic, assign) CGSize iconSize;
//@property (nonatomic, strong) UIColor *textColor;

@property (nonatomic, strong) UIColor *anchorTextColor;

@property (nonatomic, strong) UIColor *anchorTextHighlightColor;

//@property (nonatomic, copy) NSString *text;

- (void)setHighlightText:(NSString *)highlightText
                   index:(NSUInteger)index
               withColor:(UIColor *)color;


- (void)setLinkWithText:(NSString *)text
                  index:(NSUInteger)index
             attributes:(NSDictionary *)attributes
              tapAction:(void(^)(void))tapAction;

- (CGSize)sizeWithConstraint:(CGSize)constaintSize;

@end

NS_ASSUME_NONNULL_END
